<template>
<div>
  {{id}}
  <br>
  {{title}}
  <input type="text" v-model:id="name">
</div>
</template>

<script>
export default {
  name: "Message",
  props:['id','title'],
  data(){
    return {
      name
    }
  },
  activated() {
    console.log('进入组件')
  },
  deactivated() {
    console.log('离开组件')
  }
}
</script>

<style scoped>

</style>